<template>
  <div>
    <h3>{{ username }}</h3>
    <!-- 组件里面的数据想在插槽外部使用,就需要用到作用域插槽 -->
    <slot :username="username">
      <h3>加载中...</h3>
    </slot>
    <slot name="hehe"></slot>
  </div>
</template>

<script>
export default {
  setup() {
    const username = 'aaa'

    return { username }
  }
}
</script>

<style scoped>

</style>